<!-- HTML header for doxygen 1.8.13-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.13"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>MTB CAT1 Peripheral driver library: Functions</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen_style.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><a href="http://www.cypress.com/"><img alt="Logo" src="IFXCYP_one-line.png"/></a></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">MTB CAT1 Peripheral driver library</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.13 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('group__group__lin__functions.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">Functions<div class="ingroups"><a class="el" href="group__group__lin.html">LIN          (Local Interconnect Network)</a></div></div>  </div>
</div><!--header-->
<div class="contents">
<a name="details" id="details"></a><h2 class="groupheader">General Description</h2>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:gae612337973effac3385278932caed920"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#gae612337973effac3385278932caed920">Cy_LIN_DeInit</a> (LIN_CH_Type *base)</td></tr>
<tr class="memdesc:gae612337973effac3385278932caed920"><td class="mdescLeft">&#160;</td><td class="mdescRight">Deinitialization of a LIN module.  <a href="#gae612337973effac3385278932caed920">More...</a><br /></td></tr>
<tr class="separator:gae612337973effac3385278932caed920"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga022f651949b9b0da42eb49b26d6dc629"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#ga022f651949b9b0da42eb49b26d6dc629">Cy_LIN_Init</a> (LIN_CH_Type *base, const <a class="el" href="structcy__stc__lin__config__t.html">cy_stc_lin_config_t</a> *pstcConfig)</td></tr>
<tr class="memdesc:ga022f651949b9b0da42eb49b26d6dc629"><td class="mdescLeft">&#160;</td><td class="mdescRight">Initializes the LIN module.  <a href="#ga022f651949b9b0da42eb49b26d6dc629">More...</a><br /></td></tr>
<tr class="separator:ga022f651949b9b0da42eb49b26d6dc629"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gafc5157ee9701212ec438b8935e025008"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#gafc5157ee9701212ec438b8935e025008">Cy_LIN_ReadData</a> (LIN_CH_Type *base, uint8_t *data)</td></tr>
<tr class="memdesc:gafc5157ee9701212ec438b8935e025008"><td class="mdescLeft">&#160;</td><td class="mdescRight">Reads response data.  <a href="#gafc5157ee9701212ec438b8935e025008">More...</a><br /></td></tr>
<tr class="separator:gafc5157ee9701212ec438b8935e025008"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gadc187085698922054358f40f61102766"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#gadc187085698922054358f40f61102766">Cy_LIN_WriteData</a> (LIN_CH_Type *base, const uint8_t *data, uint8_t dataLength)</td></tr>
<tr class="memdesc:gadc187085698922054358f40f61102766"><td class="mdescLeft">&#160;</td><td class="mdescRight">Writes response data.  <a href="#gadc187085698922054358f40f61102766">More...</a><br /></td></tr>
<tr class="separator:gadc187085698922054358f40f61102766"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaeaf5d7ed1dad6387c6e29ae9e1e6f283"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#gaeaf5d7ed1dad6387c6e29ae9e1e6f283">Cy_LIN_Enable</a> (LIN_CH_Type *base)</td></tr>
<tr class="memdesc:gaeaf5d7ed1dad6387c6e29ae9e1e6f283"><td class="mdescLeft">&#160;</td><td class="mdescRight">Enables LIN channel.  <a href="#gaeaf5d7ed1dad6387c6e29ae9e1e6f283">More...</a><br /></td></tr>
<tr class="separator:gaeaf5d7ed1dad6387c6e29ae9e1e6f283"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga7f0d57ec29739409641ab31d55027f24"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#ga7f0d57ec29739409641ab31d55027f24">Cy_LIN_Disable</a> (LIN_CH_Type *base)</td></tr>
<tr class="memdesc:ga7f0d57ec29739409641ab31d55027f24"><td class="mdescLeft">&#160;</td><td class="mdescRight">Disables LIN channel.  <a href="#ga7f0d57ec29739409641ab31d55027f24">More...</a><br /></td></tr>
<tr class="separator:ga7f0d57ec29739409641ab31d55027f24"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gad350aa9efb6456b15bd19496c8a2fbd3"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#gad350aa9efb6456b15bd19496c8a2fbd3">Cy_LIN_SetBreakWakeupFieldLength</a> (LIN_CH_Type *base, uint8_t length)</td></tr>
<tr class="memdesc:gad350aa9efb6456b15bd19496c8a2fbd3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets LIN break/wakeup field length.  <a href="#gad350aa9efb6456b15bd19496c8a2fbd3">More...</a><br /></td></tr>
<tr class="separator:gad350aa9efb6456b15bd19496c8a2fbd3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga82271648198d79ec6b6b04d121760e47"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#ga82271648198d79ec6b6b04d121760e47">Cy_LIN_SetDataLength</a> (LIN_CH_Type *base, uint8_t length)</td></tr>
<tr class="memdesc:ga82271648198d79ec6b6b04d121760e47"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets LIN response field data length.  <a href="#ga82271648198d79ec6b6b04d121760e47">More...</a><br /></td></tr>
<tr class="separator:ga82271648198d79ec6b6b04d121760e47"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga5b3de77896f20af2c86306dce5434d44"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#ga5b3de77896f20af2c86306dce5434d44">Cy_LIN_SetChecksumType</a> (LIN_CH_Type *base, <a class="el" href="group__group__lin__enums.html#gab813994a03707cbee68cfa5894d82800">cy_en_lin_checksum_type_t</a> type)</td></tr>
<tr class="memdesc:ga5b3de77896f20af2c86306dce5434d44"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets LIN checksum type setting.  <a href="#ga5b3de77896f20af2c86306dce5434d44">More...</a><br /></td></tr>
<tr class="separator:ga5b3de77896f20af2c86306dce5434d44"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga03c597f64053b7ebe11db0d332f21af2"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#ga03c597f64053b7ebe11db0d332f21af2">Cy_LIN_SetCmd</a> (LIN_CH_Type *base, uint32_t command)</td></tr>
<tr class="memdesc:ga03c597f64053b7ebe11db0d332f21af2"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets LIN operation command.  <a href="#ga03c597f64053b7ebe11db0d332f21af2">More...</a><br /></td></tr>
<tr class="separator:ga03c597f64053b7ebe11db0d332f21af2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaeeb11daf2fc23f165651c5b81b7c82c4"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#gaeeb11daf2fc23f165651c5b81b7c82c4">Cy_LIN_SetHeader</a> (LIN_CH_Type *base, uint8_t id)</td></tr>
<tr class="memdesc:gaeeb11daf2fc23f165651c5b81b7c82c4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets LIN header for master tx header operation.  <a href="#gaeeb11daf2fc23f165651c5b81b7c82c4">More...</a><br /></td></tr>
<tr class="separator:gaeeb11daf2fc23f165651c5b81b7c82c4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga46b5fce31309f1875e4a3d994cc0257f"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#ga46b5fce31309f1875e4a3d994cc0257f">Cy_LIN_GetHeader</a> (LIN_CH_Type *base, uint8_t *id, uint8_t *parity)</td></tr>
<tr class="memdesc:ga46b5fce31309f1875e4a3d994cc0257f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns received LIN header.  <a href="#ga46b5fce31309f1875e4a3d994cc0257f">More...</a><br /></td></tr>
<tr class="separator:ga46b5fce31309f1875e4a3d994cc0257f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga545104ebfe2a6d54cc7c35cbcc5a46b3"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#ga545104ebfe2a6d54cc7c35cbcc5a46b3">Cy_LIN_SetInterruptMask</a> (LIN_CH_Type *base, uint32_t mask)</td></tr>
<tr class="memdesc:ga545104ebfe2a6d54cc7c35cbcc5a46b3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets interrupt source to be accepted.  <a href="#ga545104ebfe2a6d54cc7c35cbcc5a46b3">More...</a><br /></td></tr>
<tr class="separator:ga545104ebfe2a6d54cc7c35cbcc5a46b3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga6f1c6979953fc43f09090c792d8f4f3e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#ga6f1c6979953fc43f09090c792d8f4f3e">Cy_LIN_GetInterruptMask</a> (LIN_CH_Type *base, uint32_t *mask)</td></tr>
<tr class="memdesc:ga6f1c6979953fc43f09090c792d8f4f3e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns interrupt mask setting.  <a href="#ga6f1c6979953fc43f09090c792d8f4f3e">More...</a><br /></td></tr>
<tr class="separator:ga6f1c6979953fc43f09090c792d8f4f3e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga621860135fb27c82e6cea7488dad4543"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#ga621860135fb27c82e6cea7488dad4543">Cy_LIN_GetInterruptMaskedStatus</a> (LIN_CH_Type *base, uint32_t *status)</td></tr>
<tr class="memdesc:ga621860135fb27c82e6cea7488dad4543"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns interrupt masked status.  <a href="#ga621860135fb27c82e6cea7488dad4543">More...</a><br /></td></tr>
<tr class="separator:ga621860135fb27c82e6cea7488dad4543"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga3cccda84a6e9859c69dbebf477c11e97"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#ga3cccda84a6e9859c69dbebf477c11e97">Cy_LIN_GetInterruptStatus</a> (LIN_CH_Type *base, uint32_t *status)</td></tr>
<tr class="memdesc:ga3cccda84a6e9859c69dbebf477c11e97"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns interrupt raw status.  <a href="#ga3cccda84a6e9859c69dbebf477c11e97">More...</a><br /></td></tr>
<tr class="separator:ga3cccda84a6e9859c69dbebf477c11e97"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga09ae5f9ff1edcf886fc2abf09de8e5c2"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a> (LIN_CH_Type *base, uint32_t mask)</td></tr>
<tr class="memdesc:ga09ae5f9ff1edcf886fc2abf09de8e5c2"><td class="mdescLeft">&#160;</td><td class="mdescRight">Clears interrupt status.  <a href="#ga09ae5f9ff1edcf886fc2abf09de8e5c2">More...</a><br /></td></tr>
<tr class="separator:ga09ae5f9ff1edcf886fc2abf09de8e5c2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaa653a7971577ec2aae00f721be4f2349"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#gaa653a7971577ec2aae00f721be4f2349">Cy_LIN_GetStatus</a> (LIN_CH_Type *base, uint32_t *status)</td></tr>
<tr class="memdesc:gaa653a7971577ec2aae00f721be4f2349"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns LIN module status.  <a href="#gaa653a7971577ec2aae00f721be4f2349">More...</a><br /></td></tr>
<tr class="separator:gaa653a7971577ec2aae00f721be4f2349"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gad6d061f47fdb235761cebb7e7369112f"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#gad6d061f47fdb235761cebb7e7369112f">Cy_LIN_EnOut_Enable</a> (LIN_CH_Type *base)</td></tr>
<tr class="memdesc:gad6d061f47fdb235761cebb7e7369112f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Enables LIN channel 'en' out.  <a href="#gad6d061f47fdb235761cebb7e7369112f">More...</a><br /></td></tr>
<tr class="separator:gad6d061f47fdb235761cebb7e7369112f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gad9dbfa93695b15cac42007ede0102583"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#gad9dbfa93695b15cac42007ede0102583">Cy_LIN_EnOut_Disable</a> (LIN_CH_Type *base)</td></tr>
<tr class="memdesc:gad9dbfa93695b15cac42007ede0102583"><td class="mdescLeft">&#160;</td><td class="mdescRight">Disables LIN channel 'en' out.  <a href="#gad9dbfa93695b15cac42007ede0102583">More...</a><br /></td></tr>
<tr class="separator:gad9dbfa93695b15cac42007ede0102583"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gac9f8f70bf71701f8dc2ec50b208d381a"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#gac9f8f70bf71701f8dc2ec50b208d381a">Cy_LIN_TestMode_Enable</a> (LIN_Type *base, const <a class="el" href="structcy__stc__lin__test__config__t.html">cy_stc_lin_test_config_t</a> *lin_test_config)</td></tr>
<tr class="memdesc:gac9f8f70bf71701f8dc2ec50b208d381a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Enables LIN Testing mode.  <a href="#gac9f8f70bf71701f8dc2ec50b208d381a">More...</a><br /></td></tr>
<tr class="separator:gac9f8f70bf71701f8dc2ec50b208d381a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gae7bada6c7d973bc2dfc3f52d1076d0b0"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#gae7bada6c7d973bc2dfc3f52d1076d0b0">Cy_LIN_TestMode_Disable</a> (LIN_Type *base)</td></tr>
<tr class="memdesc:gae7bada6c7d973bc2dfc3f52d1076d0b0"><td class="mdescLeft">&#160;</td><td class="mdescRight">Disables LIN Testing mode.  <a href="#gae7bada6c7d973bc2dfc3f52d1076d0b0">More...</a><br /></td></tr>
<tr class="separator:gae7bada6c7d973bc2dfc3f52d1076d0b0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gabc994b44431ec2d606a37dd858628521"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#gabc994b44431ec2d606a37dd858628521">Cy_LIN_ErrCtl_Enable</a> (LIN_Type *base, <a class="el" href="structcy__stc__lin__test__error__config__t.html">cy_stc_lin_test_error_config_t</a> *test_error_config)</td></tr>
<tr class="memdesc:gabc994b44431ec2d606a37dd858628521"><td class="mdescLeft">&#160;</td><td class="mdescRight">Enables LIN ERROR CTL.  <a href="#gabc994b44431ec2d606a37dd858628521">More...</a><br /></td></tr>
<tr class="separator:gabc994b44431ec2d606a37dd858628521"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gad6d7af2807ea4e927061a16fc1c43f95"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__lin__functions.html#gad6d7af2807ea4e927061a16fc1c43f95">Cy_LIN_ErrCtl_Disable</a> (LIN_Type *base)</td></tr>
<tr class="memdesc:gad6d7af2807ea4e927061a16fc1c43f95"><td class="mdescLeft">&#160;</td><td class="mdescRight">Disables LIN ERROR CTL.  <a href="#gad6d7af2807ea4e927061a16fc1c43f95">More...</a><br /></td></tr>
<tr class="separator:gad6d7af2807ea4e927061a16fc1c43f95"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Function Documentation</h2>
<a id="gae612337973effac3385278932caed920"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gae612337973effac3385278932caed920">&#9670;&nbsp;</a></span>Cy_LIN_DeInit()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_DeInit </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Deinitialization of a LIN module. </p>
<p>This function deinitializes the selected LIN channel.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">base</td><td>Pointer to LIN instance channel register</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line"></div><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != <a class="code" href="group__group__lin__functions.html#gae612337973effac3385278932caed920">Cy_LIN_DeInit</a> (LIN0_CH0))</div><div class="line">    {</div><div class="line">        <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="ga022f651949b9b0da42eb49b26d6dc629"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga022f651949b9b0da42eb49b26d6dc629">&#9670;&nbsp;</a></span>Cy_LIN_Init()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_Init </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="structcy__stc__lin__config__t.html">cy_stc_lin_config_t</a> *&#160;</td>
          <td class="paramname"><em>pstcConfig</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Initializes the LIN module. </p>
<p>This function initializes LIN according to the options setup in the passed Config Struct. Several checkings are done before that and an error is returned if invalid Modes are requested.</p>
<dl class="section pre"><dt>Precondition</dt><dd>The Application must configure corresponding LIN pins (SIN, SOT) according to requirements and settings of LIN instance. And must set baud rate using SysClk. LIN I/F has internal fixed oversampling value (16). Therefore, LIN clock / 16 is actual baud rate.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">base</td><td>Pointer to LIN instance register area </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">pstcConfig</td><td>LIN module configuration. See <a class="el" href="structcy__stc__lin__config__t.html" title="LIN configuration These settings are per LIN instance. ">cy_stc_lin_config_t</a>.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line"></div><div class="line"><span class="preprocessor">#define LIN_MASTER_CHANNEL LIN0_CH0</span></div><div class="line"><span class="preprocessor">#define LIN_SLAVE_CHANNEL LIN0_CH1</span></div><div class="line"></div><div class="line">    <span class="keyword">const</span> <a class="code" href="structcy__stc__lin__config__t.html">cy_stc_lin_config_t</a> lin_0_ch0_config =</div><div class="line">    {</div><div class="line">        .<a class="code" href="structcy__stc__lin__config__t.html#aaf42f95b7833fbe9e9af9d3ba3791997">masterMode</a> = <span class="keyword">true</span>,</div><div class="line">        .linTransceiverAutoEnable = <span class="keyword">true</span>,</div><div class="line">        .breakFieldLength = 13,</div><div class="line">        .breakDelimiterLength = <a class="code" href="group__group__lin__enums.html#ggac081822aba019eda4d5a6434d775eca6a75c98bef0e054b5c77e6f90929df5736">LIN_BREAK_DILIMITER_LENGTH_4BITS</a>,</div><div class="line">        .stopBit = <a class="code" href="group__group__lin__enums.html#gga94412ac1e6b2f694e669917f366d32e5ad09cc58eb444d63fc6bf71df4b058851">LIN_ONE_STOP_BIT</a>,</div><div class="line">        .filterEnable = <span class="keyword">true</span>,</div><div class="line">    };</div><div class="line"></div><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != <a class="code" href="group__group__lin__functions.html#ga022f651949b9b0da42eb49b26d6dc629">Cy_LIN_Init</a>(LIN0_CH0, &amp;lin_0_ch0_config))</div><div class="line">    {</div><div class="line">        <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="gafc5157ee9701212ec438b8935e025008"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gafc5157ee9701212ec438b8935e025008">&#9670;&nbsp;</a></span>Cy_LIN_ReadData()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_ReadData </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>data</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Reads response data. </p>
<p>Data is read in Bytes. Maximum data length is 8-bytes.</p>
<dl class="section pre"><dt>Precondition</dt><dd>Must be run after RX_RESPONSE_DONE.</dd></dl>
<dl class="section note"><dt>Note</dt><dd>This function returns last received data set.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">data</td><td>[out] Pointer to received data. Must have enough space for current Rx data.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line"><span class="comment">/* LIN interrupt handler */</span></div><div class="line"><span class="comment">/*</span></div><div class="line"><span class="comment"> * Master Interrupt handler</span></div><div class="line"><span class="comment"> * Master Sends the header and wait for interrupts.</span></div><div class="line"><span class="comment"> * If the Interrupt is for Tx Header Done then Header is transferred properly.</span></div><div class="line"><span class="comment"> * If the interrupt is for Rx Response Done then Master reads the response.</span></div><div class="line"><span class="comment"> * If the Interrupt is for Tx Response Done then response is transferred properly.</span></div><div class="line"><span class="comment"> * Handle any Errors if there is an error interrupt.</span></div><div class="line"><span class="comment"> */</span></div><div class="line"><span class="keywordtype">void</span> lin_master_intHandler(<span class="keywordtype">void</span>)</div><div class="line">{</div><div class="line">    uint32_t status;</div><div class="line">    uint32_t maskStatus;</div><div class="line">    <a class="code" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> linStatus;</div><div class="line"></div><div class="line">    <a class="code" href="group__group__lin__functions.html#ga621860135fb27c82e6cea7488dad4543">Cy_LIN_GetInterruptMaskedStatus</a>(LIN_MASTER_CHANNEL, &amp;maskStatus);</div><div class="line"></div><div class="line">    <span class="keywordflow">if</span> ((maskStatus &amp; <a class="code" href="group__group__lin__intr__mask__macro.html#gac6cc43ba7dbe0c5716a9fc2487d6145e">LIN_INTR_ALL_ERROR_MASK_MASTER</a>) != 0u)</div><div class="line">    {</div><div class="line">        <span class="comment">/* There are some error */</span></div><div class="line">        <span class="comment">/* Handle error if needed. */</span></div><div class="line"></div><div class="line">        <span class="comment">/* Disable the channel to reset LIN status */</span></div><div class="line">        <a class="code" href="group__group__lin__functions.html#ga7f0d57ec29739409641ab31d55027f24">Cy_LIN_Disable</a>(LIN_MASTER_CHANNEL);</div><div class="line">        <span class="comment">/* Re-enable the channel */</span></div><div class="line">        <a class="code" href="group__group__lin__functions.html#gaeaf5d7ed1dad6387c6e29ae9e1e6f283">Cy_LIN_Enable</a>(LIN_MASTER_CHANNEL);</div><div class="line">    }</div><div class="line">    <span class="keywordflow">else</span></div><div class="line">    {</div><div class="line">        <span class="keywordflow">if</span>(maskStatus &amp; <a class="code" href="group__group__lin__intr__mask__macro.html#ga2b88edb63faec852fd11d5c0ab2f0bc6">LIN_INTR_TX_HEADER_DONE</a>)</div><div class="line">        {</div><div class="line">            <a class="code" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a>(LIN_MASTER_CHANNEL, LIN_INTR_TX_HEADER_DONE);</div><div class="line">        }</div><div class="line">        <span class="keywordflow">else</span> <span class="keywordflow">if</span>(maskStatus &amp; <a class="code" href="group__group__lin__intr__mask__macro.html#ga339147474b68294af1442f5af6bd71f2">LIN_INTR_TX_RESPONSE_DONE</a>)</div><div class="line">        {</div><div class="line">            <a class="code" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a>(LIN_MASTER_CHANNEL, maskStatus);</div><div class="line">        }</div><div class="line">        <span class="keywordflow">else</span> <span class="keywordflow">if</span>(maskStatus &amp; <a class="code" href="group__group__lin__intr__mask__macro.html#gae9a56849db1e242346561c36fd8d7e71">LIN_INTR_RX_RESPONSE_DONE</a>)</div><div class="line">        {</div><div class="line">            memset(dstData, 0, <a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>*<span class="keyword">sizeof</span>(dstData[0]));</div><div class="line">            linStatus = <a class="code" href="group__group__lin__functions.html#gafc5157ee9701212ec438b8935e025008">Cy_LIN_ReadData</a>(LIN_MASTER_CHANNEL, dstData);</div><div class="line">            <span class="keywordflow">if</span>(linStatus != <a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a>)</div><div class="line">            {</div><div class="line">                <span class="comment">/* Insert error handling */</span></div><div class="line">            }</div><div class="line">            <span class="keywordflow">else</span></div><div class="line">            {</div><div class="line">                status = memcmp(srcData, dstData, (<a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>*<span class="keyword">sizeof</span>(dstData[0])));</div><div class="line">                <span class="keywordflow">if</span> (status !=0)</div><div class="line">                {</div><div class="line">                    <span class="comment">/* Insert error handling */</span></div><div class="line">                }</div><div class="line">            }</div><div class="line">            <a class="code" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a>(LIN_MASTER_CHANNEL, maskStatus);    <span class="comment">/* Clear all accepted interrupt. */</span></div><div class="line">        }</div><div class="line">    }</div><div class="line">}</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="gadc187085698922054358f40f61102766"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gadc187085698922054358f40f61102766">&#9670;&nbsp;</a></span>Cy_LIN_WriteData()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_WriteData </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const uint8_t *&#160;</td>
          <td class="paramname"><em>data</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t&#160;</td>
          <td class="paramname"><em>dataLength</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Writes response data. </p>
<p>Data is written in Bytes. Maximum data length is 8-bytes. </p><dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">data</td><td>[in] Pointer to response data. </td></tr>
    <tr><td class="paramname">dataLength</td><td>[in] Data length in bytes. </td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line"><span class="comment">/* LIN reception callback */</span></div><div class="line"><span class="comment">/*</span></div><div class="line"><span class="comment"> * Master setCmd function</span></div><div class="line"><span class="comment"> * Sets the interrupt mask for desired interrupt callback notification.</span></div><div class="line"><span class="comment"> * Sets the command based on the type of command to be sent.</span></div><div class="line"><span class="comment"> * Master always sends the header.</span></div><div class="line"><span class="comment"> */</span></div><div class="line"><span class="keywordtype">void</span> lin_master_setCmd(<span class="keywordtype">void</span>)</div><div class="line">{</div><div class="line">    <a class="code" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> linStatus;</div><div class="line">    <span class="comment">/* LIN operation */</span></div><div class="line">    linStatus = <a class="code" href="group__group__lin__functions.html#ga545104ebfe2a6d54cc7c35cbcc5a46b3">Cy_LIN_SetInterruptMask</a>(LIN_MASTER_CHANNEL, LIN_INTR_TX_HEADER_DONE | LIN_INTR_TX_RESPONSE_DONE | LIN_INTR_RX_RESPONSE_DONE | <a class="code" href="group__group__lin__intr__mask__macro.html#ga4647cf9bc2f8e5f3a0a7a0cab1d06757">LIN_INTR_ALL_ERROR_MASK_SLAVE</a>);</div><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">    {</div><div class="line">          <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div><div class="line">    linStatus = <a class="code" href="group__group__lin__functions.html#ga5b3de77896f20af2c86306dce5434d44">Cy_LIN_SetChecksumType</a>(LIN_MASTER_CHANNEL,<a class="code" href="group__group__lin__enums.html#ggab813994a03707cbee68cfa5894d82800a5057883612e5853e964c48c513e2aeaf">LIN_CHECKSUM_TYPE_EXTENDED</a>);</div><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">    {</div><div class="line">          <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div><div class="line">    linStatus = <a class="code" href="group__group__lin__functions.html#gaeeb11daf2fc23f165651c5b81b7c82c4">Cy_LIN_SetHeader</a>(LIN_MASTER_CHANNEL, master_msgContext[scheduleIdx].<span class="keywordtype">id</span>);</div><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">    {</div><div class="line">         <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div><div class="line">    linStatus = <a class="code" href="group__group__lin__functions.html#ga82271648198d79ec6b6b04d121760e47">Cy_LIN_SetDataLength</a>(LIN_MASTER_CHANNEL, <a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>);</div><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">    {</div><div class="line">         <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div><div class="line"></div><div class="line">    <span class="keywordflow">if</span>((master_msgContext[scheduleIdx].<span class="keywordtype">id</span> == 0x02) || (master_msgContext[scheduleIdx].<span class="keywordtype">id</span> == 0x11))</div><div class="line">    {</div><div class="line">        linStatus = <a class="code" href="group__group__lin__functions.html#gadc187085698922054358f40f61102766">Cy_LIN_WriteData</a>(LIN_MASTER_CHANNEL, srcData, <a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>);</div><div class="line">        <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">        {</div><div class="line">             <span class="comment">/* Insert error handling */</span></div><div class="line">        }</div><div class="line"></div><div class="line">        linStatus = <a class="code" href="group__group__lin__functions.html#ga03c597f64053b7ebe11db0d332f21af2">Cy_LIN_SetCmd</a>(LIN_MASTER_CHANNEL, <a class="code" href="group__group__lin__cmd__macro.html#gaa420884eb883917d6414676767904553">LIN_CMD_TX_HEADER_TX_RESPONSE</a>);</div><div class="line">        <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">        {</div><div class="line">             <span class="comment">/* Insert error handling */</span></div><div class="line">        }</div><div class="line">    }</div><div class="line">    <span class="keywordflow">else</span></div><div class="line">    {</div><div class="line">        linStatus = <a class="code" href="group__group__lin__functions.html#ga03c597f64053b7ebe11db0d332f21af2">Cy_LIN_SetCmd</a>(LIN_MASTER_CHANNEL, <a class="code" href="group__group__lin__cmd__macro.html#ga2b16a62d26bff9be6776888b486ab469">LIN_CMD_TX_HEADER_RX_RESPONSE</a>);</div><div class="line">        <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">        {</div><div class="line">             <span class="comment">/* Insert error handling */</span></div><div class="line">        }</div><div class="line">    }</div><div class="line"></div><div class="line">}</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="gaeaf5d7ed1dad6387c6e29ae9e1e6f283"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaeaf5d7ed1dad6387c6e29ae9e1e6f283">&#9670;&nbsp;</a></span>Cy_LIN_Enable()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_Enable </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Enables LIN channel. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != <a class="code" href="group__group__lin__functions.html#gaeaf5d7ed1dad6387c6e29ae9e1e6f283">Cy_LIN_Enable</a>(LIN0_CH0))</div><div class="line">    {</div><div class="line">        <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="ga7f0d57ec29739409641ab31d55027f24"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga7f0d57ec29739409641ab31d55027f24">&#9670;&nbsp;</a></span>Cy_LIN_Disable()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_Disable </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Disables LIN channel. </p>
<p>Disabling LIN channel causes clearing of non retained registers. e.g) CMD register, INTR register, STATUS register. This behavior can be used for re-initialization, after error or abort RX operation.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != <a class="code" href="group__group__lin__functions.html#ga7f0d57ec29739409641ab31d55027f24">Cy_LIN_Disable</a>(LIN0_CH0))</div><div class="line">    {</div><div class="line">        <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="gad350aa9efb6456b15bd19496c8a2fbd3"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gad350aa9efb6456b15bd19496c8a2fbd3">&#9670;&nbsp;</a></span>Cy_LIN_SetBreakWakeupFieldLength()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_SetBreakWakeupFieldLength </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t&#160;</td>
          <td class="paramname"><em>length</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Sets LIN break/wakeup field length. </p>
<p>Normally this I/F is used for detection of the wakeup pulse.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">length</td><td>[in] Bit length of the break/wakeup field.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="ga82271648198d79ec6b6b04d121760e47"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga82271648198d79ec6b6b04d121760e47">&#9670;&nbsp;</a></span>Cy_LIN_SetDataLength()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_SetDataLength </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t&#160;</td>
          <td class="paramname"><em>length</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Sets LIN response field data length. </p>
<p>Data is in Bytes and maximum data length is 8-bytes.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">length</td><td>[in] Data length in byte</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != <a class="code" href="group__group__lin__functions.html#ga82271648198d79ec6b6b04d121760e47">Cy_LIN_SetDataLength</a>(LIN0_CH0, <a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>))</div><div class="line">    {</div><div class="line">        <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="ga5b3de77896f20af2c86306dce5434d44"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga5b3de77896f20af2c86306dce5434d44">&#9670;&nbsp;</a></span>Cy_LIN_SetChecksumType()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_SetChecksumType </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__group__lin__enums.html#gab813994a03707cbee68cfa5894d82800">cy_en_lin_checksum_type_t</a>&#160;</td>
          <td class="paramname"><em>type</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Sets LIN checksum type setting. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">type</td><td>[in] Checksum type. Refer <a class="el" href="group__group__lin__enums.html#gab813994a03707cbee68cfa5894d82800">cy_en_lin_checksum_type_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != <a class="code" href="group__group__lin__functions.html#ga5b3de77896f20af2c86306dce5434d44">Cy_LIN_SetChecksumType</a>(LIN0_CH0,<a class="code" href="group__group__lin__enums.html#ggab813994a03707cbee68cfa5894d82800a5057883612e5853e964c48c513e2aeaf">LIN_CHECKSUM_TYPE_EXTENDED</a>))</div><div class="line">    {</div><div class="line">        <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="ga03c597f64053b7ebe11db0d332f21af2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga03c597f64053b7ebe11db0d332f21af2">&#9670;&nbsp;</a></span>Cy_LIN_SetCmd()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_SetCmd </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>command</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Sets LIN operation command. </p>
<dl class="section note"><dt>Note</dt><dd>As a normal usage, following combinations are used.<ul>
<li>Master Header TX only : LIN_CMD_TX_HEADER Header TX &amp; TX response : LIN_CMD_TX_HEADER_TX_RESPONSE Header TX &amp; RX response : LIN_CMD_TX_HEADER_RX_RESPONSE</li>
<li>Slave Header RX : LIN_CMD_RX_HEADER_RX_RESPONSE TX response : LIN_CMD_TX_RESPONSE RX response : Already set when header RX As a typical usage, RX response is always set at header RX phase.</li>
<li>Wakeup frame : LIN_CMD_TX_WAKEUP Instead of above macro, you can use raw definition LIN_CH_CMD_*_Msk defined in IO header file.</li>
</ul>
</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">command</td><td>[in] Required operation command. Refer <a class="el" href="group__group__lin__cmd__macro.html">LIN Command Type Definition</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != <a class="code" href="group__group__lin__functions.html#ga03c597f64053b7ebe11db0d332f21af2">Cy_LIN_SetCmd</a>(LIN0_CH0, <a class="code" href="group__group__lin__cmd__macro.html#gaa420884eb883917d6414676767904553">LIN_CMD_TX_HEADER_TX_RESPONSE</a>))</div><div class="line">    {</div><div class="line">        <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="gaeeb11daf2fc23f165651c5b81b7c82c4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaeeb11daf2fc23f165651c5b81b7c82c4">&#9670;&nbsp;</a></span>Cy_LIN_SetHeader()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_SetHeader </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t&#160;</td>
          <td class="paramname"><em>id</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Sets LIN header for master tx header operation. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">id</td><td>[in] ID value</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line">    uint8_t <span class="keywordtype">id</span> = 0x01; <span class="comment">/* frame identifier of the predefined messages agreed between master and slave. */</span></div><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != <a class="code" href="group__group__lin__functions.html#gaeeb11daf2fc23f165651c5b81b7c82c4">Cy_LIN_SetHeader</a>(LIN0_CH0, <span class="keywordtype">id</span>))</div><div class="line">    {</div><div class="line">        <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="ga46b5fce31309f1875e4a3d994cc0257f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga46b5fce31309f1875e4a3d994cc0257f">&#9670;&nbsp;</a></span>Cy_LIN_GetHeader()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_GetHeader </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>id</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t *&#160;</td>
          <td class="paramname"><em>parity</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Returns received LIN header. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">id</td><td>[out] Received ID value. </td></tr>
    <tr><td class="paramname">parity</td><td>[out] Received parity value. Note that parity check is always done by HW automatically.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="ga545104ebfe2a6d54cc7c35cbcc5a46b3"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga545104ebfe2a6d54cc7c35cbcc5a46b3">&#9670;&nbsp;</a></span>Cy_LIN_SetInterruptMask()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_SetInterruptMask </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>mask</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Sets interrupt source to be accepted. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">mask</td><td>[in] The mask with the OR of the interrupt source to be accepted. See <a class="el" href="group__group__lin__intr__mask__macro.html">LIN ALL Interrupt Mask Definition</a> for the set of constants.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line"><span class="comment">/* LIN reception callback */</span></div><div class="line"><span class="comment">/*</span></div><div class="line"><span class="comment"> * Master setCmd function</span></div><div class="line"><span class="comment"> * Sets the interrupt mask for desired interrupt callback notification.</span></div><div class="line"><span class="comment"> * Sets the command based on the type of command to be sent.</span></div><div class="line"><span class="comment"> * Master always sends the header.</span></div><div class="line"><span class="comment"> */</span></div><div class="line"><span class="keywordtype">void</span> lin_master_setCmd(<span class="keywordtype">void</span>)</div><div class="line">{</div><div class="line">    <a class="code" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> linStatus;</div><div class="line">    <span class="comment">/* LIN operation */</span></div><div class="line">    linStatus = <a class="code" href="group__group__lin__functions.html#ga545104ebfe2a6d54cc7c35cbcc5a46b3">Cy_LIN_SetInterruptMask</a>(LIN_MASTER_CHANNEL, LIN_INTR_TX_HEADER_DONE | LIN_INTR_TX_RESPONSE_DONE | LIN_INTR_RX_RESPONSE_DONE | <a class="code" href="group__group__lin__intr__mask__macro.html#ga4647cf9bc2f8e5f3a0a7a0cab1d06757">LIN_INTR_ALL_ERROR_MASK_SLAVE</a>);</div><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">    {</div><div class="line">          <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div><div class="line">    linStatus = <a class="code" href="group__group__lin__functions.html#ga5b3de77896f20af2c86306dce5434d44">Cy_LIN_SetChecksumType</a>(LIN_MASTER_CHANNEL,<a class="code" href="group__group__lin__enums.html#ggab813994a03707cbee68cfa5894d82800a5057883612e5853e964c48c513e2aeaf">LIN_CHECKSUM_TYPE_EXTENDED</a>);</div><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">    {</div><div class="line">          <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div><div class="line">    linStatus = <a class="code" href="group__group__lin__functions.html#gaeeb11daf2fc23f165651c5b81b7c82c4">Cy_LIN_SetHeader</a>(LIN_MASTER_CHANNEL, master_msgContext[scheduleIdx].<span class="keywordtype">id</span>);</div><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">    {</div><div class="line">         <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div><div class="line">    linStatus = <a class="code" href="group__group__lin__functions.html#ga82271648198d79ec6b6b04d121760e47">Cy_LIN_SetDataLength</a>(LIN_MASTER_CHANNEL, <a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>);</div><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">    {</div><div class="line">         <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div><div class="line"></div><div class="line">    <span class="keywordflow">if</span>((master_msgContext[scheduleIdx].<span class="keywordtype">id</span> == 0x02) || (master_msgContext[scheduleIdx].<span class="keywordtype">id</span> == 0x11))</div><div class="line">    {</div><div class="line">        linStatus = <a class="code" href="group__group__lin__functions.html#gadc187085698922054358f40f61102766">Cy_LIN_WriteData</a>(LIN_MASTER_CHANNEL, srcData, <a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>);</div><div class="line">        <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">        {</div><div class="line">             <span class="comment">/* Insert error handling */</span></div><div class="line">        }</div><div class="line"></div><div class="line">        linStatus = <a class="code" href="group__group__lin__functions.html#ga03c597f64053b7ebe11db0d332f21af2">Cy_LIN_SetCmd</a>(LIN_MASTER_CHANNEL, <a class="code" href="group__group__lin__cmd__macro.html#gaa420884eb883917d6414676767904553">LIN_CMD_TX_HEADER_TX_RESPONSE</a>);</div><div class="line">        <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">        {</div><div class="line">             <span class="comment">/* Insert error handling */</span></div><div class="line">        }</div><div class="line">    }</div><div class="line">    <span class="keywordflow">else</span></div><div class="line">    {</div><div class="line">        linStatus = <a class="code" href="group__group__lin__functions.html#ga03c597f64053b7ebe11db0d332f21af2">Cy_LIN_SetCmd</a>(LIN_MASTER_CHANNEL, <a class="code" href="group__group__lin__cmd__macro.html#ga2b16a62d26bff9be6776888b486ab469">LIN_CMD_TX_HEADER_RX_RESPONSE</a>);</div><div class="line">        <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">        {</div><div class="line">             <span class="comment">/* Insert error handling */</span></div><div class="line">        }</div><div class="line">    }</div><div class="line"></div><div class="line">}</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="ga6f1c6979953fc43f09090c792d8f4f3e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga6f1c6979953fc43f09090c792d8f4f3e">&#9670;&nbsp;</a></span>Cy_LIN_GetInterruptMask()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_GetInterruptMask </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>mask</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Returns interrupt mask setting. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">mask</td><td>[out] The mask with the OR of the interrupt source which is masked. See <a class="el" href="group__group__lin__intr__mask__macro.html">LIN ALL Interrupt Mask Definition</a> for the set of constants.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line"><span class="comment">/* LIN reception callback */</span></div><div class="line"><span class="comment">/*</span></div><div class="line"><span class="comment"> * Master setCmd function</span></div><div class="line"><span class="comment"> * Sets the interrupt mask for desired interrupt callback notification.</span></div><div class="line"><span class="comment"> * Sets the command based on the type of command to be sent.</span></div><div class="line"><span class="comment"> * Master always sends the header.</span></div><div class="line"><span class="comment"> */</span></div><div class="line"><span class="keywordtype">void</span> lin_master_setCmd(<span class="keywordtype">void</span>)</div><div class="line">{</div><div class="line">    <a class="code" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> linStatus;</div><div class="line">    <span class="comment">/* LIN operation */</span></div><div class="line">    linStatus = <a class="code" href="group__group__lin__functions.html#ga545104ebfe2a6d54cc7c35cbcc5a46b3">Cy_LIN_SetInterruptMask</a>(LIN_MASTER_CHANNEL, LIN_INTR_TX_HEADER_DONE | LIN_INTR_TX_RESPONSE_DONE | LIN_INTR_RX_RESPONSE_DONE | <a class="code" href="group__group__lin__intr__mask__macro.html#ga4647cf9bc2f8e5f3a0a7a0cab1d06757">LIN_INTR_ALL_ERROR_MASK_SLAVE</a>);</div><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">    {</div><div class="line">          <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div><div class="line">    linStatus = <a class="code" href="group__group__lin__functions.html#ga5b3de77896f20af2c86306dce5434d44">Cy_LIN_SetChecksumType</a>(LIN_MASTER_CHANNEL,<a class="code" href="group__group__lin__enums.html#ggab813994a03707cbee68cfa5894d82800a5057883612e5853e964c48c513e2aeaf">LIN_CHECKSUM_TYPE_EXTENDED</a>);</div><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">    {</div><div class="line">          <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div><div class="line">    linStatus = <a class="code" href="group__group__lin__functions.html#gaeeb11daf2fc23f165651c5b81b7c82c4">Cy_LIN_SetHeader</a>(LIN_MASTER_CHANNEL, master_msgContext[scheduleIdx].<span class="keywordtype">id</span>);</div><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">    {</div><div class="line">         <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div><div class="line">    linStatus = <a class="code" href="group__group__lin__functions.html#ga82271648198d79ec6b6b04d121760e47">Cy_LIN_SetDataLength</a>(LIN_MASTER_CHANNEL, <a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>);</div><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">    {</div><div class="line">         <span class="comment">/* Insert error handling */</span></div><div class="line">    }</div><div class="line"></div><div class="line">    <span class="keywordflow">if</span>((master_msgContext[scheduleIdx].<span class="keywordtype">id</span> == 0x02) || (master_msgContext[scheduleIdx].<span class="keywordtype">id</span> == 0x11))</div><div class="line">    {</div><div class="line">        linStatus = <a class="code" href="group__group__lin__functions.html#gadc187085698922054358f40f61102766">Cy_LIN_WriteData</a>(LIN_MASTER_CHANNEL, srcData, <a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>);</div><div class="line">        <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">        {</div><div class="line">             <span class="comment">/* Insert error handling */</span></div><div class="line">        }</div><div class="line"></div><div class="line">        linStatus = <a class="code" href="group__group__lin__functions.html#ga03c597f64053b7ebe11db0d332f21af2">Cy_LIN_SetCmd</a>(LIN_MASTER_CHANNEL, <a class="code" href="group__group__lin__cmd__macro.html#gaa420884eb883917d6414676767904553">LIN_CMD_TX_HEADER_TX_RESPONSE</a>);</div><div class="line">        <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">        {</div><div class="line">             <span class="comment">/* Insert error handling */</span></div><div class="line">        }</div><div class="line">    }</div><div class="line">    <span class="keywordflow">else</span></div><div class="line">    {</div><div class="line">        linStatus = <a class="code" href="group__group__lin__functions.html#ga03c597f64053b7ebe11db0d332f21af2">Cy_LIN_SetCmd</a>(LIN_MASTER_CHANNEL, <a class="code" href="group__group__lin__cmd__macro.html#ga2b16a62d26bff9be6776888b486ab469">LIN_CMD_TX_HEADER_RX_RESPONSE</a>);</div><div class="line">        <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != linStatus)</div><div class="line">        {</div><div class="line">             <span class="comment">/* Insert error handling */</span></div><div class="line">        }</div><div class="line">    }</div><div class="line"></div><div class="line">}</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="ga621860135fb27c82e6cea7488dad4543"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga621860135fb27c82e6cea7488dad4543">&#9670;&nbsp;</a></span>Cy_LIN_GetInterruptMaskedStatus()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_GetInterruptMaskedStatus </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>status</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Returns interrupt masked status. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">status</td><td>[out] The mask with the OR of the interrupt source which occurs. See <a class="el" href="group__group__lin__intr__mask__macro.html">LIN ALL Interrupt Mask Definition</a> for the set of constants.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line"><span class="comment">/* LIN interrupt handler */</span></div><div class="line"><span class="comment">/*</span></div><div class="line"><span class="comment"> * Master Interrupt handler</span></div><div class="line"><span class="comment"> * Master Sends the header and wait for interrupts.</span></div><div class="line"><span class="comment"> * If the Interrupt is for Tx Header Done then Header is transferred properly.</span></div><div class="line"><span class="comment"> * If the interrupt is for Rx Response Done then Master reads the response.</span></div><div class="line"><span class="comment"> * If the Interrupt is for Tx Response Done then response is transferred properly.</span></div><div class="line"><span class="comment"> * Handle any Errors if there is an error interrupt.</span></div><div class="line"><span class="comment"> */</span></div><div class="line"><span class="keywordtype">void</span> lin_master_intHandler(<span class="keywordtype">void</span>)</div><div class="line">{</div><div class="line">    uint32_t status;</div><div class="line">    uint32_t maskStatus;</div><div class="line">    <a class="code" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> linStatus;</div><div class="line"></div><div class="line">    <a class="code" href="group__group__lin__functions.html#ga621860135fb27c82e6cea7488dad4543">Cy_LIN_GetInterruptMaskedStatus</a>(LIN_MASTER_CHANNEL, &amp;maskStatus);</div><div class="line"></div><div class="line">    <span class="keywordflow">if</span> ((maskStatus &amp; LIN_INTR_ALL_ERROR_MASK_MASTER) != 0u)</div><div class="line">    {</div><div class="line">        <span class="comment">/* There are some error */</span></div><div class="line">        <span class="comment">/* Handle error if needed. */</span></div><div class="line"></div><div class="line">        <span class="comment">/* Disable the channel to reset LIN status */</span></div><div class="line">        <a class="code" href="group__group__lin__functions.html#ga7f0d57ec29739409641ab31d55027f24">Cy_LIN_Disable</a>(LIN_MASTER_CHANNEL);</div><div class="line">        <span class="comment">/* Re-enable the channel */</span></div><div class="line">        <a class="code" href="group__group__lin__functions.html#gaeaf5d7ed1dad6387c6e29ae9e1e6f283">Cy_LIN_Enable</a>(LIN_MASTER_CHANNEL);</div><div class="line">    }</div><div class="line">    <span class="keywordflow">else</span></div><div class="line">    {</div><div class="line">        <span class="keywordflow">if</span>(maskStatus &amp; LIN_INTR_TX_HEADER_DONE)</div><div class="line">        {</div><div class="line">            <a class="code" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a>(LIN_MASTER_CHANNEL, LIN_INTR_TX_HEADER_DONE);</div><div class="line">        }</div><div class="line">        <span class="keywordflow">else</span> <span class="keywordflow">if</span>(maskStatus &amp; LIN_INTR_TX_RESPONSE_DONE)</div><div class="line">        {</div><div class="line">            <a class="code" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a>(LIN_MASTER_CHANNEL, maskStatus);</div><div class="line">        }</div><div class="line">        <span class="keywordflow">else</span> <span class="keywordflow">if</span>(maskStatus &amp; LIN_INTR_RX_RESPONSE_DONE)</div><div class="line">        {</div><div class="line">            memset(dstData, 0, <a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>*<span class="keyword">sizeof</span>(dstData[0]));</div><div class="line">            linStatus = <a class="code" href="group__group__lin__functions.html#gafc5157ee9701212ec438b8935e025008">Cy_LIN_ReadData</a>(LIN_MASTER_CHANNEL, dstData);</div><div class="line">            <span class="keywordflow">if</span>(linStatus != <a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a>)</div><div class="line">            {</div><div class="line">                <span class="comment">/* Insert error handling */</span></div><div class="line">            }</div><div class="line">            <span class="keywordflow">else</span></div><div class="line">            {</div><div class="line">                status = memcmp(srcData, dstData, (<a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>*<span class="keyword">sizeof</span>(dstData[0])));</div><div class="line">                <span class="keywordflow">if</span> (status !=0)</div><div class="line">                {</div><div class="line">                    <span class="comment">/* Insert error handling */</span></div><div class="line">                }</div><div class="line">            }</div><div class="line">            <a class="code" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a>(LIN_MASTER_CHANNEL, maskStatus);    <span class="comment">/* Clear all accepted interrupt. */</span></div><div class="line">        }</div><div class="line">    }</div><div class="line">}</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="ga3cccda84a6e9859c69dbebf477c11e97"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga3cccda84a6e9859c69dbebf477c11e97">&#9670;&nbsp;</a></span>Cy_LIN_GetInterruptStatus()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_GetInterruptStatus </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>status</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Returns interrupt raw status. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">status</td><td>[out] The mask with the OR of the interrupt source which occurs. See <a class="el" href="group__group__lin__intr__mask__macro.html">LIN ALL Interrupt Mask Definition</a> for the set of constants.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line"><span class="comment">/* LIN interrupt handler */</span></div><div class="line"><span class="comment">/*</span></div><div class="line"><span class="comment"> * Master Interrupt handler</span></div><div class="line"><span class="comment"> * Master Sends the header and wait for interrupts.</span></div><div class="line"><span class="comment"> * If the Interrupt is for Tx Header Done then Header is transferred properly.</span></div><div class="line"><span class="comment"> * If the interrupt is for Rx Response Done then Master reads the response.</span></div><div class="line"><span class="comment"> * If the Interrupt is for Tx Response Done then response is transferred properly.</span></div><div class="line"><span class="comment"> * Handle any Errors if there is an error interrupt.</span></div><div class="line"><span class="comment"> */</span></div><div class="line"><span class="keywordtype">void</span> lin_master_intHandler(<span class="keywordtype">void</span>)</div><div class="line">{</div><div class="line">    uint32_t status;</div><div class="line">    uint32_t maskStatus;</div><div class="line">    <a class="code" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> linStatus;</div><div class="line"></div><div class="line">    <a class="code" href="group__group__lin__functions.html#ga621860135fb27c82e6cea7488dad4543">Cy_LIN_GetInterruptMaskedStatus</a>(LIN_MASTER_CHANNEL, &amp;maskStatus);</div><div class="line"></div><div class="line">    <span class="keywordflow">if</span> ((maskStatus &amp; LIN_INTR_ALL_ERROR_MASK_MASTER) != 0u)</div><div class="line">    {</div><div class="line">        <span class="comment">/* There are some error */</span></div><div class="line">        <span class="comment">/* Handle error if needed. */</span></div><div class="line"></div><div class="line">        <span class="comment">/* Disable the channel to reset LIN status */</span></div><div class="line">        <a class="code" href="group__group__lin__functions.html#ga7f0d57ec29739409641ab31d55027f24">Cy_LIN_Disable</a>(LIN_MASTER_CHANNEL);</div><div class="line">        <span class="comment">/* Re-enable the channel */</span></div><div class="line">        <a class="code" href="group__group__lin__functions.html#gaeaf5d7ed1dad6387c6e29ae9e1e6f283">Cy_LIN_Enable</a>(LIN_MASTER_CHANNEL);</div><div class="line">    }</div><div class="line">    <span class="keywordflow">else</span></div><div class="line">    {</div><div class="line">        <span class="keywordflow">if</span>(maskStatus &amp; LIN_INTR_TX_HEADER_DONE)</div><div class="line">        {</div><div class="line">            <a class="code" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a>(LIN_MASTER_CHANNEL, LIN_INTR_TX_HEADER_DONE);</div><div class="line">        }</div><div class="line">        <span class="keywordflow">else</span> <span class="keywordflow">if</span>(maskStatus &amp; LIN_INTR_TX_RESPONSE_DONE)</div><div class="line">        {</div><div class="line">            <a class="code" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a>(LIN_MASTER_CHANNEL, maskStatus);</div><div class="line">        }</div><div class="line">        <span class="keywordflow">else</span> <span class="keywordflow">if</span>(maskStatus &amp; LIN_INTR_RX_RESPONSE_DONE)</div><div class="line">        {</div><div class="line">            memset(dstData, 0, <a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>*<span class="keyword">sizeof</span>(dstData[0]));</div><div class="line">            linStatus = <a class="code" href="group__group__lin__functions.html#gafc5157ee9701212ec438b8935e025008">Cy_LIN_ReadData</a>(LIN_MASTER_CHANNEL, dstData);</div><div class="line">            <span class="keywordflow">if</span>(linStatus != <a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a>)</div><div class="line">            {</div><div class="line">                <span class="comment">/* Insert error handling */</span></div><div class="line">            }</div><div class="line">            <span class="keywordflow">else</span></div><div class="line">            {</div><div class="line">                status = memcmp(srcData, dstData, (<a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>*<span class="keyword">sizeof</span>(dstData[0])));</div><div class="line">                <span class="keywordflow">if</span> (status !=0)</div><div class="line">                {</div><div class="line">                    <span class="comment">/* Insert error handling */</span></div><div class="line">                }</div><div class="line">            }</div><div class="line">            <a class="code" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a>(LIN_MASTER_CHANNEL, maskStatus);    <span class="comment">/* Clear all accepted interrupt. */</span></div><div class="line">        }</div><div class="line">    }</div><div class="line">}</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="ga09ae5f9ff1edcf886fc2abf09de8e5c2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga09ae5f9ff1edcf886fc2abf09de8e5c2">&#9670;&nbsp;</a></span>Cy_LIN_ClearInterrupt()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_ClearInterrupt </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>mask</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Clears interrupt status. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">mask</td><td>[in] The mask with the OR of the interrupt source to be cleared. See <a class="el" href="group__group__lin__intr__mask__macro.html">LIN ALL Interrupt Mask Definition</a> for the set of constants.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line"><span class="comment">/* LIN interrupt handler */</span></div><div class="line"><span class="comment">/*</span></div><div class="line"><span class="comment"> * Master Interrupt handler</span></div><div class="line"><span class="comment"> * Master Sends the header and wait for interrupts.</span></div><div class="line"><span class="comment"> * If the Interrupt is for Tx Header Done then Header is transferred properly.</span></div><div class="line"><span class="comment"> * If the interrupt is for Rx Response Done then Master reads the response.</span></div><div class="line"><span class="comment"> * If the Interrupt is for Tx Response Done then response is transferred properly.</span></div><div class="line"><span class="comment"> * Handle any Errors if there is an error interrupt.</span></div><div class="line"><span class="comment"> */</span></div><div class="line"><span class="keywordtype">void</span> lin_master_intHandler(<span class="keywordtype">void</span>)</div><div class="line">{</div><div class="line">    uint32_t status;</div><div class="line">    uint32_t maskStatus;</div><div class="line">    <a class="code" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> linStatus;</div><div class="line"></div><div class="line">    <a class="code" href="group__group__lin__functions.html#ga621860135fb27c82e6cea7488dad4543">Cy_LIN_GetInterruptMaskedStatus</a>(LIN_MASTER_CHANNEL, &amp;maskStatus);</div><div class="line"></div><div class="line">    <span class="keywordflow">if</span> ((maskStatus &amp; LIN_INTR_ALL_ERROR_MASK_MASTER) != 0u)</div><div class="line">    {</div><div class="line">        <span class="comment">/* There are some error */</span></div><div class="line">        <span class="comment">/* Handle error if needed. */</span></div><div class="line"></div><div class="line">        <span class="comment">/* Disable the channel to reset LIN status */</span></div><div class="line">        <a class="code" href="group__group__lin__functions.html#ga7f0d57ec29739409641ab31d55027f24">Cy_LIN_Disable</a>(LIN_MASTER_CHANNEL);</div><div class="line">        <span class="comment">/* Re-enable the channel */</span></div><div class="line">        <a class="code" href="group__group__lin__functions.html#gaeaf5d7ed1dad6387c6e29ae9e1e6f283">Cy_LIN_Enable</a>(LIN_MASTER_CHANNEL);</div><div class="line">    }</div><div class="line">    <span class="keywordflow">else</span></div><div class="line">    {</div><div class="line">        <span class="keywordflow">if</span>(maskStatus &amp; LIN_INTR_TX_HEADER_DONE)</div><div class="line">        {</div><div class="line">            <a class="code" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a>(LIN_MASTER_CHANNEL, LIN_INTR_TX_HEADER_DONE);</div><div class="line">        }</div><div class="line">        <span class="keywordflow">else</span> <span class="keywordflow">if</span>(maskStatus &amp; LIN_INTR_TX_RESPONSE_DONE)</div><div class="line">        {</div><div class="line">            <a class="code" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a>(LIN_MASTER_CHANNEL, maskStatus);</div><div class="line">        }</div><div class="line">        <span class="keywordflow">else</span> <span class="keywordflow">if</span>(maskStatus &amp; LIN_INTR_RX_RESPONSE_DONE)</div><div class="line">        {</div><div class="line">            memset(dstData, 0, <a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>*<span class="keyword">sizeof</span>(dstData[0]));</div><div class="line">            linStatus = <a class="code" href="group__group__lin__functions.html#gafc5157ee9701212ec438b8935e025008">Cy_LIN_ReadData</a>(LIN_MASTER_CHANNEL, dstData);</div><div class="line">            <span class="keywordflow">if</span>(linStatus != <a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a>)</div><div class="line">            {</div><div class="line">                <span class="comment">/* Insert error handling */</span></div><div class="line">            }</div><div class="line">            <span class="keywordflow">else</span></div><div class="line">            {</div><div class="line">                status = memcmp(srcData, dstData, (<a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>*<span class="keyword">sizeof</span>(dstData[0])));</div><div class="line">                <span class="keywordflow">if</span> (status !=0)</div><div class="line">                {</div><div class="line">                    <span class="comment">/* Insert error handling */</span></div><div class="line">                }</div><div class="line">            }</div><div class="line">            <a class="code" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a>(LIN_MASTER_CHANNEL, maskStatus);    <span class="comment">/* Clear all accepted interrupt. */</span></div><div class="line">        }</div><div class="line">    }</div><div class="line">}</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="gaa653a7971577ec2aae00f721be4f2349"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaa653a7971577ec2aae00f721be4f2349">&#9670;&nbsp;</a></span>Cy_LIN_GetStatus()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_GetStatus </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>status</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Returns LIN module status. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">status</td><td>[out] LIN module status.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line"><span class="comment">/* LIN interrupt handler */</span></div><div class="line"><span class="comment">/*</span></div><div class="line"><span class="comment"> * Master Interrupt handler</span></div><div class="line"><span class="comment"> * Master Sends the header and wait for interrupts.</span></div><div class="line"><span class="comment"> * If the Interrupt is for Tx Header Done then Header is transferred properly.</span></div><div class="line"><span class="comment"> * If the interrupt is for Rx Response Done then Master reads the response.</span></div><div class="line"><span class="comment"> * If the Interrupt is for Tx Response Done then response is transferred properly.</span></div><div class="line"><span class="comment"> * Handle any Errors if there is an error interrupt.</span></div><div class="line"><span class="comment"> */</span></div><div class="line"><span class="keywordtype">void</span> lin_master_intHandler(<span class="keywordtype">void</span>)</div><div class="line">{</div><div class="line">    uint32_t status;</div><div class="line">    uint32_t maskStatus;</div><div class="line">    <a class="code" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> linStatus;</div><div class="line"></div><div class="line">    <a class="code" href="group__group__lin__functions.html#ga621860135fb27c82e6cea7488dad4543">Cy_LIN_GetInterruptMaskedStatus</a>(LIN_MASTER_CHANNEL, &amp;maskStatus);</div><div class="line"></div><div class="line">    <span class="keywordflow">if</span> ((maskStatus &amp; LIN_INTR_ALL_ERROR_MASK_MASTER) != 0u)</div><div class="line">    {</div><div class="line">        <span class="comment">/* There are some error */</span></div><div class="line">        <span class="comment">/* Handle error if needed. */</span></div><div class="line"></div><div class="line">        <span class="comment">/* Disable the channel to reset LIN status */</span></div><div class="line">        <a class="code" href="group__group__lin__functions.html#ga7f0d57ec29739409641ab31d55027f24">Cy_LIN_Disable</a>(LIN_MASTER_CHANNEL);</div><div class="line">        <span class="comment">/* Re-enable the channel */</span></div><div class="line">        <a class="code" href="group__group__lin__functions.html#gaeaf5d7ed1dad6387c6e29ae9e1e6f283">Cy_LIN_Enable</a>(LIN_MASTER_CHANNEL);</div><div class="line">    }</div><div class="line">    <span class="keywordflow">else</span></div><div class="line">    {</div><div class="line">        <span class="keywordflow">if</span>(maskStatus &amp; LIN_INTR_TX_HEADER_DONE)</div><div class="line">        {</div><div class="line">            <a class="code" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a>(LIN_MASTER_CHANNEL, LIN_INTR_TX_HEADER_DONE);</div><div class="line">        }</div><div class="line">        <span class="keywordflow">else</span> <span class="keywordflow">if</span>(maskStatus &amp; LIN_INTR_TX_RESPONSE_DONE)</div><div class="line">        {</div><div class="line">            <a class="code" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a>(LIN_MASTER_CHANNEL, maskStatus);</div><div class="line">        }</div><div class="line">        <span class="keywordflow">else</span> <span class="keywordflow">if</span>(maskStatus &amp; LIN_INTR_RX_RESPONSE_DONE)</div><div class="line">        {</div><div class="line">            memset(dstData, 0, <a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>*<span class="keyword">sizeof</span>(dstData[0]));</div><div class="line">            linStatus = <a class="code" href="group__group__lin__functions.html#gafc5157ee9701212ec438b8935e025008">Cy_LIN_ReadData</a>(LIN_MASTER_CHANNEL, dstData);</div><div class="line">            <span class="keywordflow">if</span>(linStatus != <a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a>)</div><div class="line">            {</div><div class="line">                <span class="comment">/* Insert error handling */</span></div><div class="line">            }</div><div class="line">            <span class="keywordflow">else</span></div><div class="line">            {</div><div class="line">                status = memcmp(srcData, dstData, (<a class="code" href="group__group__lin__common__macro.html#ga5c2f843627af7f46df3294789769b490">LIN_DATA_LENGTH_MAX</a>*<span class="keyword">sizeof</span>(dstData[0])));</div><div class="line">                <span class="keywordflow">if</span> (status !=0)</div><div class="line">                {</div><div class="line">                    <span class="comment">/* Insert error handling */</span></div><div class="line">                }</div><div class="line">            }</div><div class="line">            <a class="code" href="group__group__lin__functions.html#ga09ae5f9ff1edcf886fc2abf09de8e5c2">Cy_LIN_ClearInterrupt</a>(LIN_MASTER_CHANNEL, maskStatus);    <span class="comment">/* Clear all accepted interrupt. */</span></div><div class="line">        }</div><div class="line">    }</div><div class="line">}</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="gad6d061f47fdb235761cebb7e7369112f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gad6d061f47fdb235761cebb7e7369112f">&#9670;&nbsp;</a></span>Cy_LIN_EnOut_Enable()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_EnOut_Enable </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Enables LIN channel 'en' out. </p>
<p>If linTransceiverAutoEnable in <a class="el" href="structcy__stc__lin__config__t.html" title="LIN configuration These settings are per LIN instance. ">cy_stc_lin_config_t</a> config structure is set to true then transceiver is set automatically and user need not call this function, else user has to call Cy_Status_EnOut_Enable() before sending a message and call Cy_Status_EnOut_Disable() after sending the message.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != <a class="code" href="group__group__lin__functions.html#ga022f651949b9b0da42eb49b26d6dc629">Cy_LIN_Init</a>(LIN_MASTER_CHANNEL, &amp;lin_0_ch0_config))</div><div class="line">    {</div><div class="line">        <span class="comment">/* Error processing */</span></div><div class="line">    }</div><div class="line">    <span class="comment">/* Enables the configuration changes to set Test mode */</span></div><div class="line">    <a class="code" href="group__group__lin__functions.html#gad6d061f47fdb235761cebb7e7369112f">Cy_LIN_EnOut_Enable</a>(LIN_MASTER_CHANNEL);</div><div class="line">    <span class="comment">/* Sets the Test mode configuration */</span></div><div class="line">    <span class="keyword">const</span> <a class="code" href="structcy__stc__lin__test__config__t.html">cy_stc_lin_test_config_t</a> lin_test_cfg =</div><div class="line">    {</div><div class="line">        <span class="comment">/* .chidx */</span> 0UL, <span class="comment">/* channel index */</span></div><div class="line">        <span class="comment">/* .mode */</span> 1UL</div><div class="line">    };</div><div class="line"></div><div class="line">    <a class="code" href="group__group__lin__functions.html#gac9f8f70bf71701f8dc2ec50b208d381a">Cy_LIN_TestMode_Enable</a>(LIN0, &amp;lin_test_cfg);</div><div class="line"></div><div class="line">    <span class="comment">/* Disables the configuration changes */</span></div><div class="line">    <a class="code" href="group__group__lin__functions.html#ga7f0d57ec29739409641ab31d55027f24">Cy_LIN_Disable</a>(LIN_MASTER_CHANNEL);</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="gad9dbfa93695b15cac42007ede0102583"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gad9dbfa93695b15cac42007ede0102583">&#9670;&nbsp;</a></span>Cy_LIN_EnOut_Disable()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_EnOut_Disable </td>
          <td>(</td>
          <td class="paramtype">LIN_CH_Type *&#160;</td>
          <td class="paramname"><em>base</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Disables LIN channel 'en' out. </p>
<p>If linTransceiverAutoEnable in <a class="el" href="structcy__stc__lin__config__t.html" title="LIN configuration These settings are per LIN instance. ">cy_stc_lin_config_t</a> config structure is set to true then transceiver is set automatically and user need not call this function, else user has to call Cy_Status_EnOut_Enable() before sending a message and call Cy_Status_EnOut_Disable() after sending the message.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="gac9f8f70bf71701f8dc2ec50b208d381a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gac9f8f70bf71701f8dc2ec50b208d381a">&#9670;&nbsp;</a></span>Cy_LIN_TestMode_Enable()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_TestMode_Enable </td>
          <td>(</td>
          <td class="paramtype">LIN_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="structcy__stc__lin__test__config__t.html">cy_stc_lin_test_config_t</a> *&#160;</td>
          <td class="paramname"><em>lin_test_config</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Enables LIN Testing mode. </p>
<p>This testing functionality simplifies SW development, but may also be used in the field to verify correct channel functionality.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">lin_test_config</td><td>[in] pointer to Test configuration structure.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a></td></tr>
  </table>
  </dd>
</dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line">    <span class="keywordflow">if</span>(<a class="code" href="group__group__lin__enums.html#gga516d7c6160634505fdfaea4fa051ef13a0e9cd7048d6006eddbfcd52a87285cae">CY_LIN_SUCCESS</a> != <a class="code" href="group__group__lin__functions.html#ga022f651949b9b0da42eb49b26d6dc629">Cy_LIN_Init</a>(LIN_MASTER_CHANNEL, &amp;lin_0_ch0_config))</div><div class="line">    {</div><div class="line">        <span class="comment">/* Error processing */</span></div><div class="line">    }</div><div class="line">    <span class="comment">/* Enables the configuration changes to set Test mode */</span></div><div class="line">    <a class="code" href="group__group__lin__functions.html#gad6d061f47fdb235761cebb7e7369112f">Cy_LIN_EnOut_Enable</a>(LIN_MASTER_CHANNEL);</div><div class="line">    <span class="comment">/* Sets the Test mode configuration */</span></div><div class="line">    <span class="keyword">const</span> <a class="code" href="structcy__stc__lin__test__config__t.html">cy_stc_lin_test_config_t</a> lin_test_cfg =</div><div class="line">    {</div><div class="line">        <span class="comment">/* .chidx */</span> 0UL, <span class="comment">/* channel index */</span></div><div class="line">        <span class="comment">/* .mode */</span> 1UL</div><div class="line">    };</div><div class="line"></div><div class="line">    <a class="code" href="group__group__lin__functions.html#gac9f8f70bf71701f8dc2ec50b208d381a">Cy_LIN_TestMode_Enable</a>(LIN0, &amp;lin_test_cfg);</div><div class="line"></div><div class="line">    <span class="comment">/* Disables the configuration changes */</span></div><div class="line">    <a class="code" href="group__group__lin__functions.html#ga7f0d57ec29739409641ab31d55027f24">Cy_LIN_Disable</a>(LIN_MASTER_CHANNEL);</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="gae7bada6c7d973bc2dfc3f52d1076d0b0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gae7bada6c7d973bc2dfc3f52d1076d0b0">&#9670;&nbsp;</a></span>Cy_LIN_TestMode_Disable()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_TestMode_Disable </td>
          <td>(</td>
          <td class="paramtype">LIN_Type *&#160;</td>
          <td class="paramname"><em>base</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Disables LIN Testing mode. </p>
<p>This testing functionality simplifies SW development, but may also be used in the field to verify correct channel functionality.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="gabc994b44431ec2d606a37dd858628521"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gabc994b44431ec2d606a37dd858628521">&#9670;&nbsp;</a></span>Cy_LIN_ErrCtl_Enable()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_ErrCtl_Enable </td>
          <td>(</td>
          <td class="paramtype">LIN_Type *&#160;</td>
          <td class="paramname"><em>base</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structcy__stc__lin__test__error__config__t.html">cy_stc_lin_test_error_config_t</a> *&#160;</td>
          <td class="paramname"><em>test_error_config</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Enables LIN ERROR CTL. </p>
<p>Enables HW injected channel transmitter errors. The receiver should detect these errors and report these errors through activation of corresponding interrupt causes.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area. </td></tr>
    <tr><td class="paramname">test_error_config</td><td>[in] pointer to Test Error configuration structure.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="gad6d7af2807ea4e927061a16fc1c43f95"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gad6d7af2807ea4e927061a16fc1c43f95">&#9670;&nbsp;</a></span>Cy_LIN_ErrCtl_Disable()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> Cy_LIN_ErrCtl_Disable </td>
          <td>(</td>
          <td class="paramtype">LIN_Type *&#160;</td>
          <td class="paramname"><em>base</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Disables LIN ERROR CTL. </p>
<p>Disables HW injected channel transmitter errors.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">base</td><td>[in] Pointer to LIN instance register area.</td></tr>
  </table>
  </dd>
</dl>
<dl class="retval"><dt>Return values</dt><dd>
  <table class="retval">
    <tr><td class="paramname">Refer</td><td><a class="el" href="group__group__lin__enums.html#ga516d7c6160634505fdfaea4fa051ef13">cy_en_lin_status_t</a> </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part
<div id="nav-path" class="navpath">
    <ul>
        <li class="footer">
            Generated for <b>MTB CAT1 Peripheral driver library</b> by <b>Cypress Semiconductor Corporation</b>.
            All rights reserved.
        </li>
    </ul>
</div>
-->
</body>
</html>
